﻿using System;
using System.Diagnostics;
using System.Windows.Forms;

namespace HDF.Windows.Tools.Other
{
    public partial class TranslateDetailForm : Form
    {
        public TranslateDetailForm()
        {
            InitializeComponent();
        }


        protected override void OnDeactivate(EventArgs e)
        {
            base.OnDeactivate(e);
            this.Hide();
        }



        public void SetText(string o, string t)
        {
            textBox1.Text = o;
            textBox2.Text = t;

        }

        private void 百度翻译ToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var text = textBox1.Text;

            text = Uri.EscapeDataString(text);

            Process.Start("https://fanyi.baidu.com/mtpe-individual/transText?query=" + text);
        }
    }
}
